/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * PnlListStaBuy.java
 *
 * Created on 3 ก.พ. 2553, 2:22:53
 */

package warehouse;

/**
 *
 * @author hj
 */
public class PnlListStaBuy extends javax.swing.JPanel {

    /** Creates new form PnlListStaBuy */
    public PnlListStaBuy() {
        initComponents();
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        pnlHeadListStaBuy = new javax.swing.JPanel();
        btnStaBuyListSearch = new javax.swing.JButton();
        btnStaBuyListAdd = new javax.swing.JButton();
        btnStaBuyPrint = new javax.swing.JButton();
        lblHeadListStaBuy = new javax.swing.JLabel();
        btnStaBuyListEdit = new javax.swing.JButton();
        btnStaBuyListDel = new javax.swing.JButton();
        pnlListStaBuy = new javax.swing.JPanel();
        lblSBName = new javax.swing.JLabel();
        lblSBComment = new javax.swing.JLabel();
        jScrollPane1 = new javax.swing.JScrollPane();
        txtSBComment = new javax.swing.JTextArea();
        txtSBCode = new javax.swing.JTextField();
        lblSBCode = new javax.swing.JLabel();
        jScrollPane2 = new javax.swing.JScrollPane();
        tblListStaBuy = new javax.swing.JTable();
        rbtStaBuyWait = new javax.swing.JRadioButton();
        rbtStaBuyApproval = new javax.swing.JRadioButton();
        rbtStaBuyCancel = new javax.swing.JRadioButton();
        rbtStaBuyClose = new javax.swing.JRadioButton();

        setFont(new java.awt.Font("Tahoma", 0, 12));
        setMaximumSize(new java.awt.Dimension(700, 500));
        setMinimumSize(new java.awt.Dimension(700, 500));
        setPreferredSize(new java.awt.Dimension(700, 500));
        setLayout(new java.awt.BorderLayout());

        pnlHeadListStaBuy.setBackground(new java.awt.Color(204, 255, 204));
        pnlHeadListStaBuy.setFont(new java.awt.Font("Tahoma", 0, 12));
        pnlHeadListStaBuy.setMaximumSize(new java.awt.Dimension(700, 80));
        pnlHeadListStaBuy.setMinimumSize(new java.awt.Dimension(700, 80));
        pnlHeadListStaBuy.setPreferredSize(new java.awt.Dimension(700, 80));

        btnStaBuyListSearch.setIcon(new javax.swing.ImageIcon(getClass().getResource("/icon/search_30x30.gif"))); // NOI18N

        btnStaBuyListAdd.setIcon(new javax.swing.ImageIcon(getClass().getResource("/icon/add_30x30.gif"))); // NOI18N

        btnStaBuyPrint.setIcon(new javax.swing.ImageIcon(getClass().getResource("/icon/print_30x30.gif"))); // NOI18N
        btnStaBuyPrint.setMaximumSize(new java.awt.Dimension(40, 40));
        btnStaBuyPrint.setMinimumSize(new java.awt.Dimension(40, 40));
        btnStaBuyPrint.setPreferredSize(new java.awt.Dimension(40, 40));

        lblHeadListStaBuy.setFont(new java.awt.Font("Tahoma", 1, 16));
        lblHeadListStaBuy.setText("จัดการสถานะการซื้อ");

        btnStaBuyListEdit.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        btnStaBuyListEdit.setIcon(new javax.swing.ImageIcon(getClass().getResource("/icon/edit1_30x30.gif"))); // NOI18N
        btnStaBuyListEdit.setMaximumSize(new java.awt.Dimension(75, 30));
        btnStaBuyListEdit.setMinimumSize(new java.awt.Dimension(75, 30));
        btnStaBuyListEdit.setPreferredSize(new java.awt.Dimension(75, 30));

        btnStaBuyListDel.setIcon(new javax.swing.ImageIcon(getClass().getResource("/icon/del_30x30.gif"))); // NOI18N

        javax.swing.GroupLayout pnlHeadListStaBuyLayout = new javax.swing.GroupLayout(pnlHeadListStaBuy);
        pnlHeadListStaBuy.setLayout(pnlHeadListStaBuyLayout);
        pnlHeadListStaBuyLayout.setHorizontalGroup(
            pnlHeadListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlHeadListStaBuyLayout.createSequentialGroup()
                .addGap(20, 20, 20)
                .addGroup(pnlHeadListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblHeadListStaBuy)
                    .addGroup(pnlHeadListStaBuyLayout.createSequentialGroup()
                        .addComponent(btnStaBuyListSearch, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(btnStaBuyListAdd, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(btnStaBuyListDel, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(btnStaBuyListEdit, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(10, 10, 10)
                        .addComponent(btnStaBuyPrint, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap(440, Short.MAX_VALUE))
        );
        pnlHeadListStaBuyLayout.setVerticalGroup(
            pnlHeadListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlHeadListStaBuyLayout.createSequentialGroup()
                .addGap(10, 10, 10)
                .addComponent(lblHeadListStaBuy)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(pnlHeadListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(btnStaBuyPrint, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnStaBuyListSearch, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnStaBuyListAdd, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnStaBuyListDel, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnStaBuyListEdit, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)))
        );

        add(pnlHeadListStaBuy, java.awt.BorderLayout.PAGE_START);

        lblSBName.setFont(new java.awt.Font("Tahoma", 0, 12));
        lblSBName.setText("สถานะการซื้อ :");

        lblSBComment.setFont(new java.awt.Font("Tahoma", 0, 12));
        lblSBComment.setText("หมายเหตุ :");

        txtSBComment.setColumns(12);
        txtSBComment.setFont(new java.awt.Font("Tahoma", 0, 12));
        txtSBComment.setRows(2);
        jScrollPane1.setViewportView(txtSBComment);

        txtSBCode.setFont(new java.awt.Font("Tahoma", 0, 12)); // NOI18N

        lblSBCode.setFont(new java.awt.Font("Tahoma", 0, 12));
        lblSBCode.setText("รหัสสถานะการซื้อ :");

        tblListStaBuy.setFont(new java.awt.Font("Tahoma", 0, 12)); // NOI18N
        tblListStaBuy.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null},
                {null, null},
                {null, null},
                {null, null}
            },
            new String [] {
                "รหัสสถานะการซื้อ", "สถานะการซื้อ"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.String.class, java.lang.String.class
            };
            boolean[] canEdit = new boolean [] {
                false, false
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        jScrollPane2.setViewportView(tblListStaBuy);

        rbtStaBuyWait.setFont(new java.awt.Font("Tahoma", 0, 12));
        rbtStaBuyWait.setText("รออนุมัติ");
        rbtStaBuyWait.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                rbtStaBuyWaitActionPerformed(evt);
            }
        });

        rbtStaBuyApproval.setFont(new java.awt.Font("Tahoma", 0, 12));
        rbtStaBuyApproval.setText("อนุมัติ");
        rbtStaBuyApproval.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                rbtStaBuyApprovalActionPerformed(evt);
            }
        });

        rbtStaBuyCancel.setFont(new java.awt.Font("Tahoma", 0, 12));
        rbtStaBuyCancel.setText("ยกเลิก");
        rbtStaBuyCancel.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                rbtStaBuyCancelActionPerformed(evt);
            }
        });

        rbtStaBuyClose.setFont(new java.awt.Font("Tahoma", 0, 12));
        rbtStaBuyClose.setText("ปิดใบงาน");
        rbtStaBuyClose.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                rbtStaBuyCloseActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout pnlListStaBuyLayout = new javax.swing.GroupLayout(pnlListStaBuy);
        pnlListStaBuy.setLayout(pnlListStaBuyLayout);
        pnlListStaBuyLayout.setHorizontalGroup(
            pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlListStaBuyLayout.createSequentialGroup()
                .addGroup(pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(pnlListStaBuyLayout.createSequentialGroup()
                        .addGap(20, 20, 20)
                        .addGroup(pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(lblSBComment)
                            .addComponent(lblSBCode))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jScrollPane1)
                            .addComponent(txtSBCode, javax.swing.GroupLayout.DEFAULT_SIZE, 170, Short.MAX_VALUE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(lblSBName)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(rbtStaBuyWait)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(rbtStaBuyApproval)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(rbtStaBuyCancel)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(rbtStaBuyClose))
                    .addGroup(pnlListStaBuyLayout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 680, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        pnlListStaBuyLayout.setVerticalGroup(
            pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlListStaBuyLayout.createSequentialGroup()
                .addGap(20, 20, 20)
                .addGroup(pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblSBCode)
                    .addComponent(txtSBCode, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblSBName)
                    .addComponent(rbtStaBuyWait)
                    .addComponent(rbtStaBuyApproval)
                    .addComponent(rbtStaBuyCancel)
                    .addComponent(rbtStaBuyClose))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(pnlListStaBuyLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblSBComment)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 255, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(70, Short.MAX_VALUE))
        );

        add(pnlListStaBuy, java.awt.BorderLayout.CENTER);
    }// </editor-fold>//GEN-END:initComponents

    private void rbtStaBuyWaitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_rbtStaBuyWaitActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_rbtStaBuyWaitActionPerformed

    private void rbtStaBuyApprovalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_rbtStaBuyApprovalActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_rbtStaBuyApprovalActionPerformed

    private void rbtStaBuyCancelActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_rbtStaBuyCancelActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_rbtStaBuyCancelActionPerformed

    private void rbtStaBuyCloseActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_rbtStaBuyCloseActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_rbtStaBuyCloseActionPerformed


    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton btnStaBuyListAdd;
    private javax.swing.JButton btnStaBuyListDel;
    private javax.swing.JButton btnStaBuyListEdit;
    private javax.swing.JButton btnStaBuyListSearch;
    private javax.swing.JButton btnStaBuyPrint;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JLabel lblHeadListStaBuy;
    private javax.swing.JLabel lblSBCode;
    private javax.swing.JLabel lblSBComment;
    private javax.swing.JLabel lblSBName;
    private javax.swing.JPanel pnlHeadListStaBuy;
    private javax.swing.JPanel pnlListStaBuy;
    private javax.swing.JRadioButton rbtStaBuyApproval;
    private javax.swing.JRadioButton rbtStaBuyCancel;
    private javax.swing.JRadioButton rbtStaBuyClose;
    private javax.swing.JRadioButton rbtStaBuyWait;
    private javax.swing.JTable tblListStaBuy;
    private javax.swing.JTextField txtSBCode;
    private javax.swing.JTextArea txtSBComment;
    // End of variables declaration//GEN-END:variables

}
